package cn.edu.zstu.overlappingdisappear.activity;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

import cn.edu.zstu.overlappingdisappear.R;
import cn.edu.zstu.overlappingdisappear.base.BaseActivity;

/**
 * @Author ZhuMingWei(986990501@qq.com)
 * @Date on 2019/11/6
 * @Version v1.0.0
 * @Company TODO
 * @Describle TODO
 */

public class MenuActivity extends BaseActivity implements View.OnClickListener{

    private Button btnChain;
    private Button btnChallenge;
    private Button btnGroup;
    private Button btnCustomize;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_menu);
        initView();
    }

    private void initView() {
        btnChain = findViewById(R.id.btn_train);
        btnChallenge = findViewById(R.id.btn_challenge);
        btnGroup = findViewById(R.id.btn_group);
        btnCustomize = findViewById(R.id.btn_customize);
        btnChain.setOnClickListener(this);
        btnChallenge.setOnClickListener(this);
        btnGroup.setOnClickListener(this);
        btnCustomize.setOnClickListener(this);
    }

    @Override
    public void onClick(View view) {
        Intent it;
        switch (view.getId()){
            case R.id.btn_train:
                it = new Intent(this, LevelActivity.class);
                startActivity(it);
                break;
            case R.id.btn_challenge:
                break;
            case R.id.btn_group:
                it = new Intent(this, PKActivity.class);
                startActivity(it);
                break;
            case R.id.btn_customize:
                break;
        }
    }
}
